package com.github.edu.repair.manager.domain;

import com.github.admin.edu.orm.repository.CustomRepository;
import com.github.edu.repair.manager.entity.TSysWfStep;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

import java.util.List;

/**
 * Create by IntelliJ IDEA
 * 用户：王建
 * 日期：2018-8-29
 */
public interface SysStepWfServerDomain extends CustomRepository<TSysWfStep,String> {

    /**
     * 查询步骤
     * @param step：第几步
     * @param lcbh: 流程编号
     * @return
     */
    @Query("select t from TSysWfStep t where t.step=:step and t.lcbh=:lcbh and t.jssj is null order by t.kssj desc ")
    List<TSysWfStep> getAllByStepAndLcbh(@Param("step") Integer step,@Param("lcbh")String lcbh);

}
